package com.mf.service;

import com.mf.entity.Order;
import org.springframework.data.domain.Sort;

import java.util.List;

/**
 * order
 *
 * @author: Jiang Runqing
 * @date: 2018-09-10 21:13
 */
public interface OrderService {
    /**
     * 根据条件分页查询订单信息
     *
     * @param order
     * @param page
     * @param pageSize
     * @param direction
     * @param properties
     * @return List<Order>
     */
    List<Order> list(Order order, Integer page, Integer pageSize, Sort.Direction direction, String... properties);

    /**
     * 获取订单总记录数
     *
     * @param order
     * @return
     */
    Long getCount(Order order);

    void save(Order order);

    Order getById(int id);

    void updateStatus(Order order);
}
